/*
 * @Author: zhang zhijiang 2824735304@qq.com
 * @Date: 2025-04-21 20:26:14
 * @LastEditors: zhang zhijiang 2824735304@qq.com
 * @LastEditTime: 2025-04-22 14:15:55
 * @FilePath: /linux/test_4_21/main.cc
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 */
#include"tcpserver.hpp"
//tcpserver  8888
void usage(string proc)
{
    cout<< "right usage :"<<proc<<"IP"<<"[1024+]"<<endl;
}
int main(int argc,char* argv[])
{
    if(argc!=2)
    {
        usage(argv[0]);
        exit(3);
    }
    uint16_t port = stoi(argv[1]);
    unique_ptr<tcpserver>srv(new tcpserver(port));
    srv->init();
    srv->start();
    return 0;
}